/*
 * @Author: xiaodong 565071984@qq.com
 * @Date: 2022-05-16 21:07:46
 * @LastEditors: xiaodong 565071984@qq.com
 * @LastEditTime: 2022-05-17 22:29:44
 * @FilePath: /小票/src/api/agents.js
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import request from '@/utils/request'

// 运营平台主页统计(同样适用于订单查询)
export function tjOrderMain(data) {
  return request({
    url: '/Order/tjOrderMain',
    method: 'post',
    data,
  })
}

// 获取租户账号列表
export function getTenentAccountList(data) {
  return request({
    url: '/Business/getTenentAccountList',
    method: 'post',
    data,
  })
}

// 获取设备账号列表
export function getDevAccountList(data) {
  return request({
    url: '/Business/getDevAccountList',
    method: 'post',
    data,
  })
}

// 获取能够购买的租户账号列表
export function getCanBuyTanantList(data) {
  return request({
    url: '/Business/getCanBuyTanantList',
    method: 'post',
    data,
  })
}

// 获取可续费的账号列表
export function getCanXfTanantList(data) {
  return request({
    url: '/Business/getCanXfTanantList',
    method: 'post',
    data,
  })
}

// 购买/续费 租户账号
export function buyTenatAccount(data) {
  return request({
    url: '/Order/buyTenatAccount',
    method: 'post',
    data,
  })
}

// 代理商列表
export function getAgentList(data) {
  return request({
    url: '/Business/getAgentList',
    method: 'post',
    data,
  })
}

// 可添加的代理商列表
export function getCanAgentList(data) {
  return request({
    url: '/Business/getCanAgentList',
    method: 'post',
    data,
  })
}

// 添加的代理商列表
export function addAgentUser(data) {
  return request({
    url: '/User/addAgentUser',
    method: 'post',
    data,
  })
}

//禁用或者启用用户
export function setUserDelete(data) {
  return request({
    url: '/User/setUserDelete',
    method: 'post',
    data,
  })
}
